R-Tek Scratchpad Version 1.00 TSPadDatad TPictured TCommentTextd TLogFontd Times New Roman densed BT Financial Problems nnnnnnnnnnnnnnnnnn] TCommentTextd Five Value Problems nnnnnnnnnnnnnnnnnnn] TCommentTextd Five value problems are financial problems involving these five interdependent variables:Y nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn] TCommentTextd Present Value nnnnnnnnnnnnn] TCommentTextd Future Value nnnnnnnnnnnn] TCommentTextd Number of Payment Periods nnnnnnnnnnnnnnnnnnnnnnnnn] TCommentTextd Interest per payment period nnnnnnnnnnnnnnnnnnnnnnnnnnn] TCommentTextd the Payment Value itself nnnnnnnnnnnnnnnnnnnnnnnn] TCommentTextd To solve problems of this sort, first create a five element vector and set the four known elements. Then call the function fiveval(m, n) where m is the 5 vector with the appropriate 4 values set. n is the index of the element that is to be calculated based on the other four. The function returns a new 5 vector containing the same 4 original elements with the n-th element set at the solved value. nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnznnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnznnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnznnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnznnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn] TCommentTextd Each element of the m vector must contain a particular variable. We will use the following assignments to make our program easier to read: nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnznnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn] TExpressiond TCommentTextd Present Value nnnnnnnnnnnnn] TCommentTextd Future Value nnnnnnnnnnnn] TExpressiond TCommentTextd Number of Payment Periods nnnnnnnnnnnnnnnnnnnnnnnnn] TCommentTextd The value assigned to each of these variables is its index in the vector mJ nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnznnnnnnnnnnnnnnnnnnnnnnnnnnnn] TExpressiond nPmts:3 TCommentTextd Interest per payment period nnnnnnnnnnnnnnnnnnnnnnnnnnn] TExpressiond intr:4 TExpressiond pmt:5 TCommentTextd the Payment Value itself nnnnnnnnnnnnnnnnnnnnnnnn] TExpressiond m:zmat(1,5) TCommentTextd Create a 5 vector that initially contains all zeros3 nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn] TCommentTextd Example 1: nnnnnnnnnn] TCommentTextd Calculate a monthly interest payment knowing loan value, the term of the loan, and the APR (annual percentage rate)t nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnznnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn] TExpressiond m[pv]:110000.00 TCommentTextd Amount of loan nnnnnnnnnnnnnn] TExpressiond m[fv]:0.00 TCommentTextd Indicates loan is to be completely paid off+ nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn] TExpressiond m[nPmts]:15*12 TCommentTextd 15yr loan with monthly payments nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn] TCommentTextd 8.5% APR Divide by 12 to get monthly interest. nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn] TExpressiond m[intr]:8.5%/12 TCommentTextd Use fiveval to calculate unknown and save result back into the original m vectorP nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnznnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn] TExpressiond m:fiveval(m,pmt) TExpressiond m[pmt] TCommentTextd Monthly payment determined by other 4 variables/ nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn] THardPageBreakd TCommentTextd Example 2: nnnnnnnnnn] TCommentTextd Calculate how much one can afford to borrow knowing the term of the loan, the APR, and the maximum monthly payment one can handle. nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnznnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn] TExpressiond m[fv]:0.00 TCommentTextd Indicates loan is to be completely paid off+ nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn] TExpressiond m[nPmts]:30*12 TCommentTextd 30yr loan with monthly payments nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn] TExpressiond m[intr]:8.5%/12 TCommentTextd 8.5% APR Divide by 12 to get monthly interest. nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn] TExpressiond m[pmt]:750.00 TCommentTextd Maximum affordable monthly payment" nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn] TExpressiond m:fiveval(m,pv) TCommentTextd Amount of loan one can afford to borrow' nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn] TExpressiond m[pv] TCommentTextd Example 3: nnnnnnnnnn] TCommentTextd Continue on with example 2. Consider that we borrowed the maximum we could presently afford, but with the intention of making monthly payments for only 5yrs and then paying the loan off in full. Such a payment is called a balloon payment. The problem is this: What is the balloon payment amount? We solve this by calculating the balance due on the loan after making the 60th monthly payment. We make our balloon payment at the same time we make the 60th payment so: nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnznnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnznnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnznnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnznnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnznnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnznnnnnnnnnnnnnnnnnnnnnnnnn] TExpressiond m[nPmts]:5*12 TCommentTextd The other values of m come from the calculation of fiveval in problem 2G nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnznnnnnnnnnnnnnnnnnnnnnnn] TExpressiond m:fiveval(m,fv) TCommentTextd Calculate the balance due after 60 payments+ nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn] TExpressiond m[pmt]+m[fv] TCommentTextd The balloon payment is the final monthly payment plus the balance due after making the final paymentd nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnznnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn] TCommentTextd Example 4: nnnnnnnnnn] TCommentTextd Calculate the total interest paid over the term of the loan; nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn] TExpressiond m[pv]:100000.00 TCommentTextd Borrow $100,000 nnnnnnnnnnnnnnn] TExpressiond m[fv]:0.00 TCommentTextd Pay it off nnnnnnnnnn] TExpressiond m[nPmts]:30*12 TCommentTextd 30yr loan nnnnnnnnn] TCommentTextd Interest rate nnnnnnnnnnnnn] TExpressiond m[intr]:8.5%/12 TExpressiond m:fiveval(m,pmt) TExpressiond m[pmt] TCommentTextd Calculated payment nnnnnnnnnnnnnnnnnn] THardPageBreakd TCommentTextd There are two functions to calculate the interest and principal for specific payment ranges.\ nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn] TCommentTextd ifiveval(m, p1, p2) calculates the interest paid from payment p1 to payment p2 inclusiveX nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn] TCommentTextd pfiveval(m, p1, p2) calculates the principal paid from payment p1 to payment p2 inclusiveY nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn] TCommentTextd So, the total interest on the above loan is:, nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn] TExpressiond ifiveval(m,1,m[nPmts]) TCommentTextd The total paid on the $100,000 mortgage is the amount borrowed plus the interest paid:V nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn] TExpressiond total:m[pv]+ifiveval(m,1,m[nPmts])" TCommentTextd Alternatively, you can arrive at the total more simply for this case by multiplying the payment amount by the number of payments: nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnznnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn] TExpressiond total:m[pmt]*m[nPmts] TCommentTextd and get the total interest by subtracting the principal:8 nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn] TExpressiond total-m[pv] TCommentTextd ifiveval and pfiveval are most useful for the more complicated cases of determing principal and interest between interim payments - such as determining the total interest paid on a house mortgage during a year so that the individual can take the appropriate tax deduction. nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnznnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnznnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn] TCommentTextd Example 5: nnnnnnnnnn] TCommentTextd Go back up a few lines, change the interest rate to 15%, and rerun. Now take a look at the total cost of the loan. Frightening, isn't it?! nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnznnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn] THardPageBreakd TCommentTextd Example 6: nnnnnnnnnn] TCommentTextd Examine how rapidly the loan is repaid, but first consider what fraction of each payment goes to interest(which does not help to repay the loan) nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnznnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn] TGraphd TGraphSetupDatad TTraced TExpressiond ifiveval(m,n,n)/m[pmt] TExpressiond TExpressiond TExpressiond m[nPmts] TCommentTextd You can easily see that at the beginning, almost the entire payment goes to interest so you can probably predict the shape of the curve that shows the payoff value of the loan after each payment period. nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnznnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnznnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn] TGraphd TGraphSetupDatad TTraced TExpressiond m[pv]-pfiveval(m,1,n) TExpressiond TExpressiond TExpressiond m[nPmts] TCommentTextd Yet another way of looking at this, consider a graph of total paid, total interest paid and total principal paidp nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnznnnnnnnnnnnnnnnnnnnnnnnn] TGraphd TGraphSetupDatad TTraced TExpressiond n*m[pmt] TTraced TExpressiond ifiveval(m,1,n) TTraced TExpressiond pfiveval(m,1,n) TExpressiond TExpressiond TExpressiond m[nPmts] THardPageBreakd TCommentTextd Example 7: nnnnnnnnnn] TCommentTextd You want to open a savings account and deposit the same amount every month for the next 10 years. What should your deposit be to have a total of $30000 at the end of 10 years assuming an interest rate of 5%? This differs from the preceding examples in that the first payment is made at the beginning of the first period. This form of annuity is called "annuity due". The functions available to handle annuity due calculations have the ordinary name with b (for beginning) appended. This example calls for the use of such a function, ie fivevalb(m, n). Another point to note is that the payments calculated for this kind of problem are negative. nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnznnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnznnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnznnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnznnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnznnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnznnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnznnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnznnnnnnnnnnnnnnnnnnnnnnnnnnnnn] TExpressiond m[pv]:0.00 TCommentTextd start with no money in the account" nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn] TCommentTextd amount we wish to accumulate nnnnnnnnnnnnnnnnnnnnnnnnnnnn] TExpressiond m[fv]:30000.00 TExpressiond m[nPmts]:120 TCommentTextd 10 years nnnnnnnn] TCommentTextd interest rate for deposit nnnnnnnnnnnnnnnnnnnnnnnnn] TExpressiond m[intr]:5.0%/12 TExpressiond m:fivevalb(m,pmt) TCommentTextd calculated necessary monthly deposit$ nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn] TExpressiond m[pmt] TCommentTextd Other financial functions: nnnnnnnnnnnnnnnnnnnnnnnnnn] TCommentTextd The APR is the annual percentage rate. It is the interest rate per compounding period multiplied by the number of compounding periods per year. nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnznnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn] TCommentTextd The EFF is the annual effective rate. It is the interest rate that produces the same interest as the APR, but with a single annual compounding period. nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnznnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn] TExpressiond EFFtoAPR(8.0,12) TExpressiond APRtoEFF(8.0,12) TPrinterDimensionsd TSPadInitDatad TLogFontd Times New Roman densed BT TLogFontd Arial TLogFontd Arial TLogFontd Symbol TLogFontd Symbol TNumberFormatDatad TGraphSetupDatad TPageSetupDatad 151.0 ea1.0 eB1.0 R-Tek Scratchpad Example File FINANCE